package com.bw.workonedemo02.video

import androidx.lifecycle.MutableLiveData
import com.bw.lib_base.entity.IVideoEntity
import com.bw.lib_base.mvvm.BaseViewModel
import com.bw.lib_base.net.ApiService

import dagger.hilt.android.lifecycle.HiltViewModel
import kotlinx.coroutines.flow.Flow
import javax.inject.Inject

@HiltViewModel
class IVideoViewModel @Inject constructor(val apiService: ApiService): BaseViewModel() {
    var getIVideoSuccess= MutableLiveData<IVideoEntity>()


    fun getIVideos(page:Int, pagesize:Int){
        httpRequest({apiService.getIVideo(page, pagesize)},getIVideoSuccess::postValue)
    }

}